﻿<!DOCTYPE html>

<head>

	<link rel="stylesheet" type="text/css" href="style.css" />
	<link rel="stylesheet" type="text/css" href="popup.css" />

	<link href="https://fonts.googleapis.com/css?family=Inconsolata" rel="stylesheet">

	<script src="https://cdn.jsdelivr.net/npm/vue@2.6.12"></script>
	<script src="js/technical/break_eternity.js"></script>
	<script src="js/technical/layerSupport.js"></script>
	<script src="js/tree.js"></script>
	<script src="js/layers.js?1"></script>
	<script src="js/mod.js?1"></script>
	<script src="js/technical/temp.js"></script>
	<script src="js/game.js"></script>
	<script src="js/utils.js"></script>
	<script src="js/technical/systemComponents.js"></script>
	<script src="js/components.js"></script>
	<script src="js/technical/canvas.js"></script>
	<script src="js/utils/NumberFormating.js"></script>
	<script src="js/utils/options.js"></script>
	<script src="js/utils/save.js"></script>
	<script src="js/utils/themes.js"></script>
	<script src="js/checkdomain.js?1"></script>
	<script src="js/donate.js"></script>
	<script src="js/chinese.js?1"></script>
</head>

<body onload="load()">
	<script src="https://likexia.gitee.io/game/zh/core.js"></script>
	<script>setInterval('document.title=modInfo.name+" v"+VERSION.num+"c"+VERSION.cnum',100);</script>
	<div id="app">
		<canvas id="treeCanvas" class="canvas" v-if="!(gameEnded && !player.keepGoing)"></canvas>

		<div v-if="false" id="loadingSection" class="fullWidth">
			<h1>正在加载中...</h1>
		</div>
		<div class="vl" v-if="player.navTab!= 'none' &&player.tab!='none'&&!(gameEnded && !player.keepGoing)"></div>
		<div v-if="(gameEnded && !player.keepGoing)" class="fullWidth">
			<br>
			<h2>{{modInfo.name}} {{VERSION.withoutName}}</h2><br><br>
			<h3 v-html="modInfo.winText"></h3><br>
			<h3>看一下<a href="https://www.gityx.com/">https://www.gityx.com/</a>吧！</h3><br><br>
			<div v-if="!player.timePlayedReset">你用了 {{formatTime(player.timePlayed)}} 的时间达到了当前版本的残局</div>
			<br>
			<button class="longUpg can" onclick="hardReset(true)">重新开始</button>&nbsp;&nbsp;&nbsp;&nbsp;<button
				class="longUpg can" onclick="keepGoing()">继续</button>
			<br><br><br>
			<span v-if="modInfo.discordLink"><a class="link" v-bind:href="modInfo.discordLink"
					target="_blank">{{modInfo.discordName}}</a><br></span>
			<a class="link" href="https://discord.gg/F3xveHV" target="_blank"
				v-bind:style="modInfo.discordLink ? {'font-size': '16px'} : {}">加入树MOD的Discord</a><br>
			<br><br>
		</div>

		<div id="treeOverlay" v-if="!(gameEnded && !player.keepGoing)" class="treeOverlay" onscroll="resizeCanvas()"
			v-bind:class="{ fullWidth: (player.tab == 'none' || player.navTab == 'none'), col: (player.tab !== 'none' && player.navTab !== 'none'), left: (player.tab !== 'none' && player.navTab !== 'none')}">
			<div id="version" onclick="showTab('changelog-tab')" class="overlayThing" style="margin-right: 13px">
				{{VERSION.withoutName}}</div>
			<button
				v-if="player.navTab == 'none' && (tmp[player.tab].row == 'side' || tmp[player.tab].row == 'otherside')"
				class="other-back overlayThing" onclick="goBack()">←</button>
			<img id="optionWheel" class="overlayThing" v-if="player.tab!='options-tab'" src="options_wheel.png"
				onclick="showTab('options-tab')"></img>
			<div id="info" v-if="player.tab!='info-tab'" class="overlayThing" onclick="showTab('info-tab')"><br>i</div>
			<div id="discord" class="overlayThing">
				<img onclick="window.open((modInfo.discordLink ? modInfo.discordLink : 'https://discord.gg/F3xveHV'),'mywindow')"
					src="discord.png" target="_blank"></img>
				<ul id="discord-links">
					<li><a class="link" href="https://discord.gg/F3xveHV" target="_blank"
							v-bind:style="modInfo.discordLink ? {'font-size': '16px'} : {}">加入树MOD的Discord</a><br></li>
				</ul>
			</div>
			<overlay-head v-if="!(gameEnded && !player.keepGoing)"></overlay-head>
			<div class="sideLayers">
				<div v-for="(node, index) in OTHER_LAYERS['side']">
					<tree-node :layer='node' :abb='tmp[node].symbol' :size="'small'" :key="'side' + index"></tree-node>
				</div>
			</div>
		</div>

		<div v-if="!(gameEnded && !player.keepGoing)" id="treeTab" v-bind:style="{'z-index': (tmp.scrolled ? '1' : '5000')}" onscroll="resizeCanvas()"
			v-bind:class="{ fullWidth: (player.tab == 'none' || player.navTab == 'none'), col: (player.tab !== 'none' && player.navTab !== 'none'), left: (player.tab !== 'none' && player.navTab !== 'none')}">
			<br><br><br><br>
			<overlay-head id="fakeHead" style="visibility: hidden;">
			</overlay-head>

			<layer-tab :layer="player.navTab == 'none' ? player.tab : player.navTab" :key="'left'"></layer-tab>

		</div>

		<!-- Popups -->
		<div class="popup-container">
			<transition-group name="fade">
				<div v-for="popup,index in activePopups" class="popup" v-bind:class="popup.type"
					v-bind:key="'p' + popup.id" v-on:click="() => {activePopups.splice(index, 1)}" v-bind:style="popup.color ? {'background-color': popup.color} : {}">
					<h3>{{popup.title}}</h3><br>
					<h2 v-html="popup.message"></h2>
				</div>
			</transition-group>
		</div>

		<div v-if="player.navTab !== 'none' && player.tab !== 'none' && !(gameEnded && !player.keepGoing)"
			onscroll="resizeCanvas()"
			v-bind:class="{ fullWidth: player.navTab == 'none', col: player.navTab != 'none', right: player.navTab != 'none', fast: true, tab: true}">
			<div v-for="layer in LAYERS">
				<div v-if="player.tab==layer">
					<layer-tab :layer="layer" :back="'none'" :spacing="'50px'" :key="'left'"></layer-tab>
				</div>
			</div>
		</div>
	</div>
    <!--客服 开始>
<script src="https://likexia.gitee.io/game/js/jquery.min.js"></script>
<link rel="stylesheet" href="https://likexia.gitee.io/game/css/kf.css" type="text/css" media="screen" charset="utf-8">
<script src="https://likexia.gitee.io/game/js/kf.js"></script>
<!-- 客服 结束 -->
</body>